// 导入接口函数
import { findHeadCategory } from '@/api/home'
export default {
  namespaced: true,
  state: ({
    navs: []
  }),
  mutations: {
    setNavs (state, payload) {
      state.navs = payload
    }
  },
  actions: {
    async getNavsAction ({ commit }, payload) {
      const res = await findHeadCategory()
      // console.log(res)
      commit('setNavs', res.result)
    }
  }
}
